<template>
  <div id="app">
    <router-view />
  </div>
</template>
<script setup>

const debounce = (fn, delay) => {
  let timer = null
  return function () {
    let context = this
    let args = arguments
    clearTimeout(timer)
    timer = setTimeout(function () {
      fn.apply(context, args)
    }, delay)
  }
}

const _ResizeObserver = window.ResizeObserver
window.ResizeObserver = class ResizeObserver extends _ResizeObserver {
  constructor(callback) {
    callback = debounce(callback, 16)
    super(callback)
  }
}
</script>
<style lang="scss">
* {
  padding: 0;
  margin: 0;
}

html,
body,
#app {
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: rgb(1, 1, 25);
  text-align: center;
  line-height: 1;
}

#Device,
#monitor,
#warn,
#InfoList {
  .el-date-editor .el-range-input {
    font-size: 16px;
  }
  .el-range-input {
    color: #07e5ff;
  }

  /* Safari，Chrome WebKit browsers */
  .el-range-input::-webkit-input-placeholder {
    color: rgba(93, 179, 255, 0.5);
  }

  /* 火狐 Mozilla Firefox 4 to 18 */
  .el-range-input:-moz-placeholder {
    color: rgba(93, 179, 255, 0.5);
  }

  /* 火狐 Mozilla Firefox 19+ */
  .el-range-input::-moz-placeholder {
    color: rgba(93, 179, 255, 0.5);
  }

  /* Internet Explorer 10+ */
  .el-range-input:-ms-input-placeholder {
    color: rgba(93, 179, 255, 0.5);
  }
  .el-date-editor .el-range__icon {
    color: rgba(93, 179, 255, 0.5);
    padding: 0 10px;
  }

  .el-table--group::after,
  .el-table::before {
    background-color: transparent;
  }
  // 表格头部
  .el-table th.el-table__cell > .cell {
    color: #00b0ff;
    font-size: 18px;
    font-weight: 600;
  }
  // 表格内容
  .el-table {
    ::-webkit-scrollbar {
      width: 10px;
      height: 10px;
    }
  }

  .el-table tr {
    background: transparent !important;
    color: #fff;
  }
  .el-table tr:hover {
    background: rgba(84, 220, 242, 0.15) !important;
  }
  .el-table--border .el-table__cell {
    border: 1px solid #3e6381;
  }
  .el-table--border,
  .el-table--group {
    border: 1px solid #3e6381;
  }
  .el-table--border::after {
    background-color: transparent;
  }

  .el-range-input {
    background: none;
  }

  /* Safari，Chrome WebKit browsers */
  .el-input__inner::-webkit-input-placeholder {
    color: rgba(93, 179, 255, 0.5);
  }

  /* 火狐 Mozilla Firefox 4 to 18 */
  .el-input__inner:-moz-placeholder {
    color: rgba(93, 179, 255, 0.5);
  }

  /* 火狐 Mozilla Firefox 19+ */
  .el-input__inner::-moz-placeholder {
    color: rgba(93, 179, 255, 0.5);
  }

  /* Internet Explorer 10+ */
  .el-input__inner:-ms-input-placeholder {
    color: rgba(93, 179, 255, 0.5);
  }

  .el-range-separator {
    font-size: 18px;
    color: rgba(93, 179, 255, 0.5);
  }
  .el-dialog__wrapper {
    z-index: 2222 !important;
  }
  .el-dialog {
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(5px);
    border-radius: 20px;
    transform: translate(-50%, -50%);

    .el-dialog__title {
      color: rgba(93, 179, 255, 0.5);
    }
    .el-dialog__headerbtn .el-dialog__close {
      color: rgba(93, 179, 255, 0.5);
      font-size: 20px;
    }
  }
  .el-button {
    background: transparent;
    span {
      // color: #fff;
      font-size: 18px;
    }

    border: 1px solid #409eff;

    &:active {
      border: 1px solid rgba(64, 158, 255, 0.5);
    }
  }
  .el-button--text {
    border: none;
  }
  .el-button--default {
    &:hover {
      background: #003a6aed !important;
    }
    // border: 1px solid rgba(84, 220, 242, 0.5);
  }
  .el-pagination__total {
    color: #d1e9ff;
    font-size: 18px;
  }
  .el-pagination__jump {
    color: #d1e9ff;
    font-size: 18px;
  }
  .el-pager li {
    color: #ffffff;
  }
  .el-pagination.is-background .btn-prev {
    background: rgba(82, 171, 255, 0.14);
  }
  .el-pagination.is-background .btn-next {
    background: rgba(82, 171, 255, 0.14);
  }

  .el-pager li {
    background: rgba(82, 171, 255, 0.14);
  }
  .el-pager .is-active {
    background: #00b0ff;
    color: #fff;
  }
  .el-form-item__label {
    color: #fff;
    font-size: 18px;
  }
  .el-form-item__error {
    font-size: 16px;
  }

  .el-input__wrapper {
    background-color: #041a3b;
    border: 1px solid transparent;
    box-shadow: none !important;
    border-radius: 6px;
    color: #fff;
    font-size: 18px;
  }

  .el-table--border .el-table__inner-wrapper::after,
  .el-table--border::after,
  .el-table--border::before,
  .el-table__inner-wrapper::before {
    background: none !important;
  }
}

.el-select-dropdown {
  background: #003775;
}

.el-popper {
  background: #003775 !important;
  text-align: left;
  border: 1px solid #298afa !important;
}

.el-popper.is-light {
  box-shadow: none !important;
}
.el-select__popper.el-popper {
  box-shadow: none !important;
}
.el-popper__arrow {
  display: none;
}
.el-date-table td.disabled div {
  font-weight: normal !important;
  color: #ccc !important;
  background: rgba(255, 255, 255, 0.2) !important;
}
.start-date .el-date-table-cell {
  background: rgba(66, 143, 178, 0.3) !important;
}
.el-date-range-picker__time-header .el-input__inner {
  padding: 0 16px !important;
  height: 32px !important;
  line-height: 32px !important;
  border: 1px solid #0083c5 !important;
  font-size: 13.5px !important;
}
.el-date-range-picker__time-header .el-input__wrapper {
  padding: 0 !important;
}
.el-time-spinner__item.is-active:not(.is-disabled) {
  color: #03dadb !important;
}

.el-picker-panel .el-time-panel {
  border: 1px solid #0083c5 !important;
  background: #003775 !important;
}
.el-date-table td.in-range .el-date-table-cell {
  background: rgba(66, 143, 178, 0.3) !important;
}
.el-button.is-text:not(.is-disabled):focus,
.el-button.is-text:not(.is-disabled):hover {
  background: none !important;
  color: #00b0ff;
}
.el-button.is-text:not(.is-disabled) {
  color: #00b0ff;
}
</style>
